package com.qhy.service.imp;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.qhy.mapper.TbProjectstypeMapper;
import com.qhy.pojo.TbProjectstype;
import com.qhy.pojo.TbProjectstypeExample;
import com.qhy.service.IProjectTypeService;

@Service
public class ProjectTypeService implements IProjectTypeService {
	
	
	@Resource
	private TbProjectstypeMapper mapper;
	
	public List<TbProjectstype> query(TbProjectstypeExample example) {
		return mapper.selectByExample(example);
	}

	public boolean addtype(TbProjectstype type) {
		return mapper.insertSelective(type)==1?true:false;
	}

	public int delete(Integer pstId) {
		return mapper.deleteByPrimaryKey(pstId);
	}

	public int updateById(TbProjectstype type) {
		return mapper.updateByPrimaryKeySelective(type);
	}
	
	
	
	
	
	
}
